<template>
	<view class="contentPage">
		<web-view :src="url" bindmessage="getMessage"></web-view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				url: '',
			}
		},
		onLoad(e) {
			let fileUrl = decodeURIComponent(e.url) // decodeURIComponent 函数可把字符串作为 URI 组件进行编码。
			this.url =
				`https://api-tms.reallyedu.com/html/pdf.html?url=${fileUrl}`;
		}
	}
</script>
